/**
 * OW2 FraSCAti Examples : HelloWorld POJO
 * Copyright (C) 2008-2010 INRIA, University of Lille 1
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 2 of the License, or (at your option) any later version.
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 *
 * Author: Haderer Nicolas
 *
 * Contributor(s): 
 */
package fr.univlille1.pji96.website;

import java.io.IOException;
import java.util.List;

import javax.ws.rs.Consumes;
import javax.ws.rs.FormParam;
import javax.ws.rs.GET;
import javax.ws.rs.POST;
import javax.ws.rs.Path;
import javax.ws.rs.QueryParam;

public interface IWebSite {
	
	
	@GET
	@Path("/getAllDatabase")
	@Consumes("application/x-www-form-urlencoded")
	public String getAllDatabase();
	
	@GET
	@Path("/getFilInString")
	@Consumes("application/x-www-form-urlencoded")
	public String getFilInString(@QueryParam("name")String nameQuery) throws IOException;
	
	
	@POST
	@Path("/addQuery")
	@Consumes("application/x-www-form-urlencoded")
	public String addQuery(
			@FormParam("nom")String nom,
			@FormParam("point")String point,
			@FormParam("exp")String exp,
			@FormParam("sensor")String sensor,
			@FormParam("options")String options,
			List<String> badges) throws IOException;
	
	@GET
	@Path("/getExp")
	@Consumes("application/x-www-form-urlencoded")
	public String[] getExp(@QueryParam("chercheur")String chercheur) throws IOException;
	
	
	@GET
	@Path("/calculeNotes")
	@Consumes("application/x-www-form-urlencoded")
	public String calculeNotes() throws IOException;
	
	@GET
	@Path("/calculeNoteGlobal")
	@Consumes("application/x-www-form-urlencoded")
	public void calculeNoteGlobal() throws IOException;
	
	
	@GET
	@Path("/rankUsers")
	@Consumes("application/x-www-form-urlencoded")
	public void rankUsers() throws IOException;
	
	@GET
	@Path("/getClassement")
	@Consumes("application/x-www-form-urlencoded")
	public String getClassement(@QueryParam("user")String user) throws IOException;
	
	// Méthodes de connexion
	public boolean findUser(String mail, String pass) throws IOException;
	public  String getSha1 (String pass);
}
